package com.wyiot.pet.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.wyiot.pet.model.dto.PetDTO;
import com.wyiot.pet.model.entity.PetDO;
import com.wyiot.pet.model.vo.AddressVO;
import com.wyiot.pet.model.vo.PetVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * @author Laiqm
 * @since 2022/3/24
 */
@Mapper
public interface PetMapper extends BaseMapper<PetDO> {
    @Select("select pet_name, pet_type, pet_size, pet_weight, pet_medical_history from pet where user_id = #{userId}")
    Page<PetVO> selectListByUserId(Page page , Long userId);
}
